package com.ruoyi.asset.workman.service;

import com.ruoyi.asset.workman.domain.Workman;
import com.ruoyi.asset.workman.domain.bo.WorkmanSearchBo;
import com.ruoyi.asset.workman.domain.vo.WorkmanVo;
import com.ruoyi.common.core.domain.PageQuery;
import com.ruoyi.common.core.page.TableDataInfo;

import java.util.Collection;
import java.util.List;

/**
 * 作业人员导入明细Service接口
 *
 * @author cc
 * @date 2023-08-29
 */
public interface IWorkmanService {

    Boolean batchInsertOrUpdate(List<Workman> voList);

    /**
     * 数据导入
     */
    List<String>  importExcel(String excelUrl, String serviceType);

    /**
     * 校验并批量删除
     */
    Boolean deleteWithValidByIds(Collection<Long> ids, Boolean isValid);

    /**
     * 查询作业人员列表
     */
    TableDataInfo<WorkmanVo> queryPageList(WorkmanSearchBo searchBo, PageQuery pageQuery);

    /**
     * 导出作业人员
     */
    List<WorkmanVo> exportWorkman(WorkmanSearchBo searchBo);

    /**
     * 按服务类型统计作业人员
     */
    List statisticsWorkmanByServiceType(String serviceType);

    int getByServiceType(String serviceType);

    int getCommunityByServiceType(String serviceType,String communityNo);

    int getCommunityByServiceTypeAndDate(String serviceType,String communityNo,String date);

    Integer getWorkmanByDateAndCommunity(String date,String community);
}
